<#include "/view/templates/ace/ace-inc.ftl">
<@html>
<@head import=true editor=true upload=true>
<script type="text/javascript" charset="utf-8">
$(function() {
	//bfsu.html('${base}/site/back/index','');
});



function changeSite(id){
	if(id){
		$.ajax({
			url:'${base}/index/saveChangeSite',
			data:{siteId:id},
			async:false,
			success:function(){
				window.location.reload(); 
			}
		});
		
	}else{
		alert("必须选择一个网站!");
		return false;
	}
	
}
</script>
<style>
.sidebar{
display:none;
}
</style>
</@head>
<@body head=true foot=true>
	<div class="main-container no-skin">
			<!-- #section:basics/sidebar -->
			<script type="text/javascript">
				try{ace.settings.check('sidebar' , 'fixed')}catch(e){}
			</script>
			<#list headmenus as menu>
				<#if (!roleCodes?exists) || roleCodes?size == 0 || (roleCodes?exists && SecurityContext.hasMenu(menu,roleCodes))>
					<#if menu.subMenus?exists && menu.subMenus?size gt 0>
					<div id="${menu.id}" class="sidebar responsive">
				
						<ul class="nav nav-list">
				
								<li class="dropdown open active">
									<a href="#" class="dropdown-toggle">
										<i class="menu-icon fa fa-desktop"></i>
										<span class="menu-text">
											${menu.title}
										</span>
				
										<b class="arrow fa fa-angle-down"></b>
									</a>
				
									<b class="arrow"></b>
									<#if menu.subMenus?exists && menu.subMenus?size gt 0>
									<ul class="submenu">
										<#list menu.subMenus as smenu>
										<#if (!roleCodes?exists)|| (roleCodes?exists && SecurityContext.hasMenu(smenu,roleCodes))>
										<li class="">
											<a  href="javascript:bfsu.html('${base}${smenu.url}', null, '${smenu.title}');" onclick="$(this).parent().siblings().removeClass('active');$(this).parent().addClass('active');">
												<i class="menu-icon fa fa-caret-right"></i>
												${smenu.title}
											</a>
				
											<b class="arrow"></b>
										</li>
										</#if>
										</#list>
									</ul>
									</#if>
								</li>
						</ul>
					</div>
					<#else>
					<div id="${menu.id}" class="sidebar responsive">
				
						<ul class="nav nav-list">
				
								<li class="dropdown open active">
									<a href="#" class="dropdown-toggle">
										<i class="menu-icon fa fa-desktop"></i>
										<span class="menu-text">
											${menu.title}
										</span>
				
									</a>
				
									<b class="arrow"></b>
									
								</li>
						</ul>
					</div>
					</#if>
				</#if>
			</#list>
			<div id="categoryMenus" class="sidebar responsive">
				
				<ul class="nav nav-list">
		
					
					<#list categoryMenus as menu>
					<li class="dropdown open active">
						<a href="#" class="dropdown-toggle">
							<i class="menu-icon fa fa-desktop"></i>
							<span class="menu-text">
								${menu.title}
							</span>

							<b class="arrow fa fa-angle-down"></b>
						</a>

						<b class="arrow"></b>
						<#if menu.subMenus?exists && menu.subMenus?size gt 0>
						<ul class="submenu">
							<#list menu.subMenus as smenu>
							<li class="">
								<a  href="javascript:bfsu.html('${base}${smenu.url}', null, '${smenu.title}');" onclick="$(this).parent().siblings().removeClass('active');$(this).parent().addClass('active');">
									<i class="menu-icon fa fa-caret-right"></i>
									${smenu.title}
									
								</a>

								<b class="arrow"></b>
							</li>
							</#list>
						</ul>
						</#if>
					</li>
					</#list>
				</ul>
			</div>
		<div class="main-content">
			<@col class="col-xs-12 col-sm-12 col-md-12 col-lg-12" id="bscenter">
			</@col>
		</div>
	</div>
</@body>
</@html>